package org.tlipoca.smcomment.client;

import org.genntii.smcommon.result.Result;
import org.genntii.smdomain.dto.CommentImageDTO;
import org.genntii.smdomain.entity.CommentImage;
import org.genntii.smdomain.vo.CommentImageVO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.ArrayList;
import java.util.HashMap;

@FeignClient("sm-commentImage")
public interface CommentImageClient {

    @PostMapping("/comment_image")
    Result addCommentImage(@RequestBody ArrayList<CommentImageDTO> commentImageDTOList);

    @DeleteMapping("/comment_image/comment/{commentId}")
    Result deleteCommentImageByCommentId(@PathVariable Long commentId);

    @PostMapping("/comment_image/comment")
    Result<HashMap<Long, ArrayList<CommentImage>>> getCommentImageGroupByCommentIdList(@RequestBody ArrayList<Long> commentIds);
}
